﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using AnyGrid.Demo.Models;

namespace AnyGrid.Demo.Controllers
{
    public class HomeController : Controller
    {
        public FakeEntityService Service { get; set; }

        public ActionResult Index()
        {
            var model = new GridViewModel<ListRow>(Service.SelectAll());
            return View(model);
        }

        public HomeController()
        {
            Service = new FakeEntityService();
        }
    }
}
